tree.using('tree.ui');

var proxy = new tree.io.rpc.JSON_Proxy('/rpc');

var table = new Table();

var homepages = proxy.call_method('get_homepages', []);

var offset = 0;
for(var page in homepages)
{
    var url = homepages[page];
    var vbox = new VBox();
    vbox.add(new Label(page));
    vbox.add(new Label(url));
    table.add(vbox, 0, offset);
    offset += 1;
}

tree.ui.Window.show hbox
